/*
 * @Author: KKKKKK
 * @Date: 2021-01-10 12:08:35
 * @LastEditors: KKKKKK
 * @LastEditTime: 2021-01-10 12:08:35
 */
import axios from './config'
import url from './url'
const baseUrl = process.env.VUE_APP_BASE_URL

/* 账号信息 */
// 新增账号信息
const accountInfoCreate = (params) => axios.post(baseUrl + url.accountInfo.create, params)

// 删除账号信息
const accountInfoDelete = (id) => axios.delete(baseUrl + url.accountInfo.delete + `/${id}`)

// 修改账号信息
const accountInfoUpdate = (params, id) => axios.post(baseUrl + url.accountInfo.update + `/${id}`, params)

// 获取某个账号信息
const accountInfoLoad = (id) => axios.get(baseUrl + url.accountInfo.load + `/${id}`)

// 获取账号信息列表
const accountInfoPage = (params) => axios.get(baseUrl + url.accountInfo.page, { params })

export default {
    accountInfoCreate,
    accountInfoDelete,
    accountInfoUpdate,
    accountInfoLoad,
    accountInfoPage,
}